import request from '@/utils/request'

// 查询工资编报
export function updateAgencyVerify(data) {
  return request({
    url: '/agencyVerifyController/updateAgencyVerify',
    method: 'post',
    data
  })
}

// 单位上报
export function reportUnitSalary(data) {
  return request({
    url: '/agencyVerifyController/reportUnitSalary',
    method: 'post',
    data
  })
}

// 单位撤销上报
export function reportRevokeUnitSalary(data) {
  return request({
    url: '/agencyVerifyController/reportRevokeUnitSalary',
    method: 'post',
    data
  })
}

// 单位上报退回
export function reportUnitSalaryBack(data) {
  return request({
    url: '/agencyVerifyController/reportUnitSalaryBack',
    method: 'post',
    data
  })
}

// 根据单位id获取审核信息
export function getAgencyVerifyByAgencyId(agencyId) {
  return request({
    url: '/agencyVerifyController/getAgencyVerifyByAgencyId/' + agencyId,
    method: 'get'
  })
}

// 根据单位id获取实发工资<=0的人数
export function getPaidWagesCount(agencyId) {
  return request({
    url: '/salaryMonthEndController/getPaidWagesCount',
    method: 'get',
    params: {
      'agencyId': agencyId
    }
  })
}

// 根据单位id获取未审核人数
export function getUnreviewedPersonCount(agencyId) {
  return request({
    url: '/salaryMonthEndController/getUnreviewedPersonCount',
    method: 'get',
    params: {
      agencyId: agencyId
    }
  })
}


// 根据单位ID获取是否允许上报
export function getsubmitable(agencyId) {
  return request({
    url: '/agencySalaryController/getSubmitAble',
    method: 'get',
    params: {
      agencyId
    }
  })
}
